<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>

<body>
    <script>
        // 如 从1打印到100

        for (var index = 1; index <= 100; index++) {
            console.log(index);
        }
        // 声明一个index变量，输出所有小于等于这个变量的值
        let index = 10
        for (let index = 10; index <= 10 && index >= 0; index--) {
            console.log(index);

        }        
    </script>
</body>

</html>